﻿{% extends "gma/base.html" %}
{% load static %}
{% load mytag %}

<!-- CONTENT
  =====================================================================-->

{% block content %}

<div class="page__hd">
    <h1 class="page__title">
        <i class="fa fa-archive weui_grid_icon_fa" style="font-size: 32px;"> </i>
    </h1>
    <p class="page__desc"> 用户{{ user.uid }}登录数据详情（{{ day }}）: </p>
</div>

<div class="page__bd">
{#    <div class="weui-cells__title"> 登录IP和端口 </div>#}
{#    <div class="weui-cells">#}
{#        {% for batch, begin, end in days %}#}
{#        <a class="weui-cell weui-cell_access" href="{% url 'gma:user_login_detail' user.uid batch %}">#}
{#            <div class="weui-cell__bd"> <p> <i class="fa fa-calendar-alt"></i>  {{ batch }} </p> </div>#}
{#            <div class="weui-cell__ft">  </div>#}
{#        </a>#}
{#        {% endfor %}#}
{#    </div>#}

    {% for log in logs %}
    <div class="weui-form-preview">
{#        <div class="weui-form-preview__hd">#}
{#            <div class="weui-form-preview__item">#}
{#                <label class="weui-form-preview__label"> 类型 </label>#}
{#                <em class="weui-form-preview__value"> {{ log.action }} </em>#}
{#            </div>#}
{#        </div>#}
        <div class="weui-form-preview__bd">
             <div class="weui-form-preview__item">
                <label class="weui-form-preview__label"> 时间 </label>
                <span class="weui-form-preview__value"> {{ log.time }} </span>
            </div>

            <div class="weui-form-preview__item">
                <label class="weui-form-preview__label"> 登录IP </label>
                <span class="weui-form-preview__value"> {{ log.ip }} </span>
            </div>

            <div class="weui-form-preview__item">
                <label class="weui-form-preview__label"> 登录端口 </label>
                <span class="weui-form-preview__value"> {{ log.port }} </span>
            </div>

            <div class="weui-form-preview__item">
                <label class="weui-form-preview__label"> 操作 </label>
                <span class="weui-form-preview__value"> {{ log.action }} </span>
            </div>

            <div class="weui-form-preview__item">
                <label class="weui-form-preview__label"> 详情 </label>
                <span class="weui-form-preview__value"> {{ log.detail }} </span>
            </div>
        </div>
    </div>
    <br>
    {% endfor %}
</div>

<div class="page__ft">
    <a href="{% url 'gma:home' %}">
        <span class="bottom-logo">
           HiBao
       </span>
    </a>
</div>

{% endblock content %}


<!-- SCRIPT
  =====================================================================-->

{% block extra_js %}


{% endblock extra_js %}